<template>
  <SearchTable model-url="/data/movie" :search-items="item.search" :table-items="item.table" :form-items="item.form" />
</template>

<script lang="ts">
import { defineComponent, reactive } from 'vue'
import SearchTable from '@/components/SearchTable/index.vue'
// import { useRouter } from 'vue-router'
export default defineComponent({
  name: 'MovieData',
  components: {
    SearchTable
  },
  props: {},
  setup() {
    const item = reactive({
      search: [{ prop: 'name', label: '名称', type: 'input' }],
      table: [
        { prop: 'name', label: '名称' },
        { prop: 'genre', label: '类型', width: '300' },
        { prop: 'datePublished', label: '上映日期', width: '300' },
      ],
      form: [
        { prop: 'name', label: '名称', type: 'input' },
        { prop: 'genre', label: '类型',  type: 'input' },
        { prop: 'datePublished', label: '上映日期', type: 'input' },
      ]
    })

    return {
      item
    }
  },
})
</script>

<style lang="scss" scoped>
//
</style>
